﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace PepsiCo.Business
{
    public partial class pepsi_Role : BaseClass
    {
        public Right GetRight(int functionID)
        {
            var function_role = DB.pepsi_Function_Roles.FirstOrDefault(p => p.FunctionID == functionID && p.RoleID == this.RoleId);
            if (function_role == null) return Right.None;
            return (Right)function_role.Right;
        }
    }
}
